<?php
namespace app\home\validate;
use think\Validate;
class User extends Validate{
    protected	$rule=		[
        'tell'=>'require|length:11|regex:1[34758]{1}\d{9}|unique:user',
        'picCode'=>'require|captcha',
        'pwd'=>'require|confirm:pwd2'		
    ];

    protected	$message=	[
        'tell.require'=>'手机号码必须填',
        'tell.length'=>'手机号只能11位',
        'tell.regex'=>'手机号码不正确',
        'tell.unique'=>'手机号码以注册',
        'picCode.require'=>'验证码必须填',
        'picCode.captcha'=>'验证码不正确',
        'pwd.require'=>'密码必须填',
        'pwd2.require'=>'确认密码必须填',
        'pwd.confirm'=>'两次密码不一致',			
    ];
}